Well, that depends how you want to go about it.
If you want to send the first 4 people to a different location that reach that node, you can use a simple counter.
If the first person that reaches the node, triggers the action, you will need to find a way to pick out the other 3.
In case they are in a race, it would be easy to select the number 2,3 and 4 and re-locate them.
Maybe I am missing something, but all of the above seems relatively easy to accomplish with Lapper.
At the moment, I am not making anything, but have worked on a cruise-script in the past (search CfL (Cruise for Lapper)) and have assisted others with their cruise-scripts.
The main thing I noticed in these scripts, is that they are static, while I think it would be great to have a dynamic script, that can be used on any track and any configuration, without having the adjust the script it self.
Since Lapper has a database attached, I think that should be doable, but since I don't cruise myself, I am interested to hear what such script would need to contain (like must haves and nice to have features).
There are often questions about cruise-scripts and I think there are a few Lapper-scripts out there already, but what if I would take a blank piece of paper and would start drawing a cruise-script from the ground up.
Only limitations are that Lapper must be able handle handle the desired things.
Since I am not cruising myself, I am asking the (cruising) community:
- What are the things a Cruise-script MUST have?
- What are the things that would be nice to have?
To make absolutely sure, I am not making any promises I am going to build such script and even if I would start it, no promises to finishes it at some point.
The reason for that is my current personal situation (I don't want to explain that any further), but getting to start such script, might be giving me a chance to get back up.
So, drop in your ideas/wishes (in English of course) and we will see what might come off it.
Any posts that are (partly) unrelated to my request, will be removed in order to keep this thread as clean as possible.
Maybe I am not understanding the request, but why would you want such function?
I mean, it's very easy to user either a GlobalVar or a PlayerVar to act like a switch that decides if a sub is or isn't executed.
IF ( UserInGroup( "IPAddress",$userName ) == 1 ) THEN cmdLFS("/kick " . GetCurrentPlayerVar("userName") ); ENDIF EndEvent
I just realised that above code will check if the userName is in the Blacklist.txt , while you want to check the IPAdress.
So here's another piece of code to do just that:
This section is about Lapper and when someone asks a question about that, they will get a proper answer.
It's not up to me to judge what someone is doing with Lapper.
We are here to help people as long as they are polite and show that they are making an effort themselfs.
To avoid further discussion about this, I'm closing this thread as the question that's been asked, has been answered.
The answer you are looking for is in the releasenotes of the latest versions of Lapper:
NOTE: Since Version 7.0.4.4 contains changes for the RegisterNodeAction() & RegisterZoneAction() Sub Callbacks. The Sub callback requires now 2 values. See example below!!
The code below can be used in a seperate Lapper module (see included file) and will save the IP Adress of a player when he joins the track.
As you can see, there are two ways of getting the IPAdress, by either using the CurrentPlayer variable as well as reading any players variable using PlayerVar combined with the username.
The screenshot is to proof that the data is actualy stored in the Lapper database.
CatchEvent OnNewPlayerJoin( $userName ) # Player event OnNewPlayerJoin_IP_Saving(); EndCatchEvent
I already made a registration system for Lapper.
This doesn't do anything with IP addresses, but if you understand the code, it wouldn't be too hard to include that.
See this posting for the actual script: https://www.lfs.net/forum/post/1921021#post1921021
globalMsg means sending a message to every player and since it is in the OnConnect event, it means that it sends a message to all connected players at the moment a new player connects.
Have a look in the Lapper section to find several scripts how to deal with saving and retrieving values.
Yes, that can be done.
Not in GripPB but in storedvalue.dbs
DriftPB = Storing driftscores (file can only be handled by Lapper it self)
GripPB = Storing laptimes (file can only be handled by Lapper it self)
storedvalue = Storing everything a user wants to store
Pitboard - V2.12 (information screen about split times, gaps in front and behind you, ect)
Changelog:
- Renamed BL2 and BL2R to BL3 and BL3R, because rallytrack has moved to 3rd config of BL
- Added BL2, since that was added as BL config on the last LFS update
Change the extension of the file to .lpr and add them to addonsused.lpr to be able to use it.
Sounds like a driftmeter, which is included as module in the Lapper download en I think there might be one or two other versions on this forum as well.